//打印页面的内容
//传递参数为标签，会打印标签的内容，注意样式问题

function printdiv(printpage)
{//打印
    var newstr = printpage.innerHTML;
    var oldstr = document.body.innerHTML;
    document.body.innerHTML =newstr;
    window.print();
    document.body.innerHTML=oldstr;
    return false;
}



function print_btn(tableid)
{
    var div_print=document.getElementById(tableid);
    printdiv(div_print);
}
